package com.sec.android.app.myfiles.feature.smarttip;

import android.app.Activity;
import android.content.ActivityNotFoundException;
import android.content.Intent;
import android.view.View;

import com.samsung.android.sdk.slinkcloud.CloudGatewayConstants;
import com.samsung.android.sdk.slinkcloud.CloudGatewayStorageUtils;
import com.sec.android.app.myfiles.R;
import com.sec.android.app.myfiles.activity.GetMoreSpaceActivity;
import com.sec.android.app.myfiles.feature.CloudMgr;
import com.sec.android.app.myfiles.info.AppConstants;
import com.sec.android.app.myfiles.log.Log;
import com.sec.android.app.myfiles.util.PreferenceUtils;
import com.sec.android.app.myfiles.util.UiUtils;


public class SmartTipImp {

    private static final String TAG = "SmartTip";

    private Activity mActivity;
    private static int smartTipState;
    private static int smartTipType;

    public SmartTipImp(Activity activity) {
        mActivity = activity;
    }

    public static boolean isSmartTipIncluded() {
        boolean bRet = true;
        try {
            Class.forName("com.samsung.android.widget.SemTipPopup");
        } catch (ClassNotFoundException e) {
            Log.d(TAG, "Smart Tip Pop-up is not supported.");
            bRet = false;
        }
        return bRet;
    }

    public void createSmartTipPopup(View view, int type) {
        clearSmartTipPopup();
    }

    private boolean isSmartTipShowing() {
        return false;
    }

    public void clearSmartTipPopup() {
    }

    public void saveSmartTipTypeBeforeRotate() {
        if (isSmartTipShowing()) {
            Log.d(TAG, "saveSmartTipTypeBeforeRotate() ] smartTipType = " + smartTipType + " (0: GMS, 1: CLOUD");
            PreferenceUtils.setPreviousTipType(mActivity, smartTipType);
        }
    }

    public void saveSmartTipStateBeforeRotate() {
        if (isSmartTipShowing()) {
            Log.d(TAG, "saveSmartTipStateBeforeRotate() ] smartTipState = " + smartTipState + " (0: DISMISS, 1: SHOW, 2: EXPAND)");
            PreferenceUtils.setPreviousTipState(mActivity, smartTipState);
        }
    }
}
